package com.share.device.domain.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.math.BigDecimal;
import java.util.List;

/**
 * 柜机管理VO
 * 
 * @author         
 * @date 2025-06-24
 */
@Schema(description = "柜机管理VO")
public class CabinetManagementVO
{
    /** 柜机基本信息 */
    @Schema(description = "柜机基本信息")
    private CabinetInfo cabinetInfo;

    /** 插槽信息列表 */
    @Schema(description = "插槽信息列表")
    private List<SlotInfo> slotInfoList;

    /** 统计信息 */
    @Schema(description = "统计信息")
    private StatisticsInfo statisticsInfo;

    /** 位置信息 */
    @Schema(description = "位置信息")
    private LocationInfo locationInfo;

    public void setCabinetInfo(CabinetInfo cabinetInfo) 
    {
        this.cabinetInfo = cabinetInfo;
    }

    public CabinetInfo getCabinetInfo() 
    {
        return cabinetInfo;
    }

    public void setSlotInfoList(List<SlotInfo> slotInfoList) 
    {
        this.slotInfoList = slotInfoList;
    }

    public List<SlotInfo> getSlotInfoList() 
    {
        return slotInfoList;
    }

    public void setStatisticsInfo(StatisticsInfo statisticsInfo) 
    {
        this.statisticsInfo = statisticsInfo;
    }

    public StatisticsInfo getStatisticsInfo() 
    {
        return statisticsInfo;
    }

    public void setLocationInfo(LocationInfo locationInfo) 
    {
        this.locationInfo = locationInfo;
    }

    public LocationInfo getLocationInfo() 
    {
        return locationInfo;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("cabinetInfo", getCabinetInfo())
            .append("slotInfoList", getSlotInfoList())
            .append("statisticsInfo", getStatisticsInfo())
            .append("locationInfo", getLocationInfo())
            .toString();
    }

    @Schema(description = "柜机基本信息")
    public static class CabinetInfo {
        private Long id;
        private String cabinetNo;
        private String name;
        private String cabinetTypeName;
        private Long totalSlots;
        private Long freeSlots;
        private Long usedSlots;
        private Long availableNum;
        private String status;
        private String statusDesc;
        private String description;

        public void setId(Long id) 
        {
            this.id = id;
        }

        public Long getId() 
        {
            return id;
        }

        public void setCabinetNo(String cabinetNo) 
        {
            this.cabinetNo = cabinetNo;
        }

        public String getCabinetNo() 
        {
            return cabinetNo;
        }

        public void setName(String name) 
        {
            this.name = name;
        }

        public String getName() 
        {
            return name;
        }

        public void setCabinetTypeName(String cabinetTypeName) 
        {
            this.cabinetTypeName = cabinetTypeName;
        }

        public String getCabinetTypeName() 
        {
            return cabinetTypeName;
        }

        public void setTotalSlots(Long totalSlots) 
        {
            this.totalSlots = totalSlots;
        }

        public Long getTotalSlots() 
        {
            return totalSlots;
        }

        public void setFreeSlots(Long freeSlots) 
        {
            this.freeSlots = freeSlots;
        }

        public Long getFreeSlots() 
        {
            return freeSlots;
        }

        public void setUsedSlots(Long usedSlots) 
        {
            this.usedSlots = usedSlots;
        }

        public Long getUsedSlots() 
        {
            return usedSlots;
        }

        public void setAvailableNum(Long availableNum) 
        {
            this.availableNum = availableNum;
        }

        public Long getAvailableNum() 
        {
            return availableNum;
        }

        public void setStatus(String status) 
        {
            this.status = status;
        }

        public String getStatus() 
        {
            return status;
        }

        public void setStatusDesc(String statusDesc) 
        {
            this.statusDesc = statusDesc;
        }

        public String getStatusDesc() 
        {
            return statusDesc;
        }

        public void setDescription(String description) 
        {
            this.description = description;
        }

        public String getDescription() 
        {
            return description;
        }
    }

    @Schema(description = "插槽信息")
    public static class SlotInfo {
        private Long id;
        private String slotNo;
        private String status;
        private String statusDesc;
        private PowerBankInfo powerBank;

        public void setId(Long id) 
        {
            this.id = id;
        }

        public Long getId() 
        {
            return id;
        }

        public void setSlotNo(String slotNo) 
        {
            this.slotNo = slotNo;
        }

        public String getSlotNo() 
        {
            return slotNo;
        }

        public void setStatus(String status) 
        {
            this.status = status;
        }

        public String getStatus() 
        {
            return status;
        }

        public void setStatusDesc(String statusDesc) 
        {
            this.statusDesc = statusDesc;
        }

        public String getStatusDesc() 
        {
            return statusDesc;
        }

        public void setPowerBank(PowerBankInfo powerBank) 
        {
            this.powerBank = powerBank;
        }

        public PowerBankInfo getPowerBank() 
        {
            return powerBank;
        }
    }

    @Schema(description = "充电宝信息")
    public static class PowerBankInfo {
        private Long id;
        private String powerBankNo;
        private BigDecimal electricity;
        private String status;
        private String statusDesc;

        public void setId(Long id) 
        {
            this.id = id;
        }

        public Long getId() 
        {
            return id;
        }

        public void setPowerBankNo(String powerBankNo) 
        {
            this.powerBankNo = powerBankNo;
        }

        public String getPowerBankNo() 
        {
            return powerBankNo;
        }

        public void setElectricity(BigDecimal electricity) 
        {
            this.electricity = electricity;
        }

        public BigDecimal getElectricity() 
        {
            return electricity;
        }

        public void setStatus(String status) 
        {
            this.status = status;
        }

        public String getStatus() 
        {
            return status;
        }

        public void setStatusDesc(String statusDesc) 
        {
            this.statusDesc = statusDesc;
        }

        public String getStatusDesc() 
        {
            return statusDesc;
        }
    }

    @Schema(description = "统计信息")
    public static class StatisticsInfo {
        private Long totalSlots;
        private Long occupiedSlots;
        private Long freeSlots;
        private Long availablePowerBanks;
        private Long chargingPowerBanks;
        private Long faultPowerBanks;
        private BigDecimal averageElectricity;

        public void setTotalSlots(Long totalSlots) 
        {
            this.totalSlots = totalSlots;
        }

        public Long getTotalSlots() 
        {
            return totalSlots;
        }

        public void setOccupiedSlots(Long occupiedSlots) 
        {
            this.occupiedSlots = occupiedSlots;
        }

        public Long getOccupiedSlots() 
        {
            return occupiedSlots;
        }

        public void setFreeSlots(Long freeSlots) 
        {
            this.freeSlots = freeSlots;
        }

        public Long getFreeSlots() 
        {
            return freeSlots;
        }

        public void setAvailablePowerBanks(Long availablePowerBanks) 
        {
            this.availablePowerBanks = availablePowerBanks;
        }

        public Long getAvailablePowerBanks() 
        {
            return availablePowerBanks;
        }

        public void setChargingPowerBanks(Long chargingPowerBanks) 
        {
            this.chargingPowerBanks = chargingPowerBanks;
        }

        public Long getChargingPowerBanks() 
        {
            return chargingPowerBanks;
        }

        public void setFaultPowerBanks(Long faultPowerBanks) 
        {
            this.faultPowerBanks = faultPowerBanks;
        }

        public Long getFaultPowerBanks() 
        {
            return faultPowerBanks;
        }

        public void setAverageElectricity(BigDecimal averageElectricity) 
        {
            this.averageElectricity = averageElectricity;
        }

        public BigDecimal getAverageElectricity() 
        {
            return averageElectricity;
        }
    }

    @Schema(description = "位置信息")
    public static class LocationInfo {
        private Long locationId;
        private String locationName;
        private String areaName;
        private String stationName;
        private String address;

        public void setLocationId(Long locationId) 
        {
            this.locationId = locationId;
        }

        public Long getLocationId() 
        {
            return locationId;
        }

        public void setLocationName(String locationName) 
        {
            this.locationName = locationName;
        }

        public String getLocationName() 
        {
            return locationName;
        }

        public void setAreaName(String areaName) 
        {
            this.areaName = areaName;
        }

        public String getAreaName() 
        {
            return areaName;
        }

        public void setStationName(String stationName) 
        {
            this.stationName = stationName;
        }

        public String getStationName() 
        {
            return stationName;
        }

        public void setAddress(String address) 
        {
            this.address = address;
        }

        public String getAddress() 
        {
            return address;
        }
    }
} 